_require local "../../basis.smi"
_require local "./absyn.sig"

structure Absyn =
struct
  datatype exp =
      EVAR of string
    | EAPP of exp * exp
    | ETUPLE of exp list
    | EINT of int
    | FN of pat * exp
    | LET of decl list * exp
    | UNIT
    | SEQ of exp * exp
    | CODE of string
  and pat =
      PVAR of string
    | PAPP of string * pat
    | PTUPLE of pat list
    | PLIST of pat list * pat option
    | PINT of int
    | WILD
    | AS of string * pat
  and decl =
      VB of pat * exp
  and rule =
      RULE of pat * exp
  val printRule : ((string -> unit) * (string -> unit)) -> rule -> unit
end
